package models

import (
	"time"

	"gitee.com/gao-deguang/easy-chat/pkg/constant"
	"go.mongodb.org/mongo-driver/bson/primitive"
)

type ChatLog struct {
	ID primitive.ObjectID `bson:"_id,omitempty" json:"id,omitempty"`

	ConversationId string            `bson:"conversationId"`
	ChatType       constant.ChatType `bson:"chatType"`
	SendId         string            `bson:"sendId"`
	RecvId         string            `bson:"recvId"`
	MsgFrom        int               `bson:"msgFrom"`
	MsgType        constant.Mtype    `bson:"msgType"`
	MsgContent     string            `bson:"msgContent"`
	SendTime       int64             `bson:"sendTime"`
	Status         int               `bson:"status"`
	ReadRecords    []byte            `bson:"readRecords"`

	CreateAt time.Time `bson:"createAt" json:"createAt"`
	UpdateAt time.Time `bson:"updateAt" json:"updateAt"`
}
